﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Akronus.TaskScheduler
{
    /// <summary>
    /// This service is used to fetch and save the information about task state. 
    /// </summary>
    public interface ITaskInfoDataService
    {
        /// <summary>
        /// Saves the task info.
        /// </summary>
        /// <param name="taskLog">The task log.</param>
        void SaveTaskInfo(TaskInfo taskLog);

        /// <summary>
        /// Gets the task infos.
        /// </summary>
        /// <returns>The task infos.</returns>
        IList<TaskInfo> GetTaskInfos();

        /// <summary>
        /// Gets the task info.
        /// </summary>
        /// <param name="taskName">Name of the task.</param>
        /// <returns>The task info.</returns>
        TaskInfo GetTaskInfo(string taskName);

        /// <summary>
        /// Gets the task infos.
        /// </summary>
        /// <param name="taskType">Type of the task.</param>
        /// <returns></returns>
        IList<TaskInfo> GetTaskInfos(string taskType);
    }
}
